import React from 'react'
import styles from '../assets/css/comment.css'
class Comment extends React.Component {
    constructor(props){
        super(props)
        console.log(props);
    }
    render() {
        const arr = []
        this.props.list.map((item,index)=>{
            arr.push(<CommentItem key={index} item={item} />)
        })
        return arr;
    }
}

function CommentItem(props) {
    console.log(styles)
    return <h1 className={styles.beige} style={{border:"1px solid #ccc"}}>{props.item.user}:{props.item.content}</h1>
}

export  default Comment
